<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="zh">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
<meta name="generator" content="Doxygen 1.12.0"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>LxLog: Logger类 参考</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr id="projectrow">
  <td id="projectalign">
   <div id="projectname">LxLog
   </div>
   <div id="projectbrief">日志库</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- 制作者 Doxygen 1.12.0 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function() { codefold.init(0); });
/* @license-end */
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>首页</span></a></li>
      <li class="current"><a href="annotated.html"><span>类</span></a></li>
      <li><a href="files.html"><span>文件</span></a></li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>类列表</span></a></li>
      <li><a href="classes.html"><span>类索引</span></a></li>
      <li><a href="hierarchy.html"><span>类继承关系</span></a></li>
      <li><a href="functions.html"><span>类成员</span></a></li>
    </ul>
  </div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function(){ initResizable(false); });
/* @license-end */
</script>
</div><!-- top -->
<div id="doc-content">
<div class="header">
  <div class="summary">
<a href="#pub-methods">Public 成员函数</a> &#124;
<a href="#pub-static-methods">静态 Public 成员函数</a> &#124;
<a href="#pri-methods">Private 成员函数</a> &#124;
<a href="#pri-attribs">Private 属性</a> &#124;
<a href="class_logger-members.html">所有成员列表</a>  </div>
  <div class="headertitle"><div class="title">Logger类 参考</div></div>
</div><!--header-->
<div class="contents">

<p><code>#include &lt;<a class="el" href="_logger_8h_source.html">Logger.h</a>&gt;</code></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pub-methods" name="pub-methods"></a>
Public 成员函数</h2></td></tr>
<tr class="memitem:a68cafca721107a954d85043a553dd217" id="r_a68cafca721107a954d85043a553dd217"><td class="memItemLeft" align="right" valign="top">virtual&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a68cafca721107a954d85043a553dd217">~Logger</a> ()=default</td></tr>
<tr class="separator:a68cafca721107a954d85043a553dd217"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3de1b6ed57224b98699fa1fb4d69537f" id="r_a3de1b6ed57224b98699fa1fb4d69537f"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a3de1b6ed57224b98699fa1fb4d69537f">asyncLog</a> (std::string_view content, <a class="el" href="class_log.html#a3718f3e276c3d3e23b58a3b8236d196e">Log::LogLevel</a> level=<a class="el" href="class_log.html#a3718f3e276c3d3e23b58a3b8236d196eaa603905470e2a5b8c13e96b579ef0dba">Log::LogLevel::Debug</a>, <a class="el" href="class_log.html#ae9a5b0a1962f5076860bde2221f8e9e4">Log::Output</a> out=<a class="el" href="class_log.html#ae9a5b0a1962f5076860bde2221f8e9e4abccaa4aa80831b76c11240a16447975f">Log::Output::Console</a>, std::string_view path=&quot;./AppLog/&quot;, const std::source_location &amp;location=std::source_location::current())</td></tr>
<tr class="separator:a3de1b6ed57224b98699fa1fb4d69537f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a67fac285fd603d742a2e0eea7783e9b6" id="r_a67fac285fd603d742a2e0eea7783e9b6"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a67fac285fd603d742a2e0eea7783e9b6">syncLog</a> (std::string_view content, <a class="el" href="class_log.html#a3718f3e276c3d3e23b58a3b8236d196e">Log::LogLevel</a> level=<a class="el" href="class_log.html#a3718f3e276c3d3e23b58a3b8236d196eaa603905470e2a5b8c13e96b579ef0dba">Log::LogLevel::Debug</a>, <a class="el" href="class_log.html#ae9a5b0a1962f5076860bde2221f8e9e4">Log::Output</a> out=<a class="el" href="class_log.html#ae9a5b0a1962f5076860bde2221f8e9e4abccaa4aa80831b76c11240a16447975f">Log::Output::Console</a>, std::string_view path=&quot;./AppLog/&quot;, const std::source_location &amp;location=std::source_location::current())</td></tr>
<tr class="separator:a67fac285fd603d742a2e0eea7783e9b6"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:adcdbfe0302dd53c9db3d355ddee8a3b6" id="r_adcdbfe0302dd53c9db3d355ddee8a3b6"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#adcdbfe0302dd53c9db3d355ddee8a3b6">startLogThread</a> ()</td></tr>
<tr class="separator:adcdbfe0302dd53c9db3d355ddee8a3b6"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa223fb9d3d6becff1ee3ae8c40ec11f3" id="r_aa223fb9d3d6becff1ee3ae8c40ec11f3"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#aa223fb9d3d6becff1ee3ae8c40ec11f3">stopLogThread</a> ()</td></tr>
<tr class="separator:aa223fb9d3d6becff1ee3ae8c40ec11f3"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pub-static-methods" name="pub-static-methods"></a>
静态 Public 成员函数</h2></td></tr>
<tr class="memitem:ad8c2e8259462504427739fbaf2e056bd" id="r_ad8c2e8259462504427739fbaf2e056bd"><td class="memItemLeft" align="right" valign="top">static <a class="el" href="class_logger.html">Logger</a> &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ad8c2e8259462504427739fbaf2e056bd">getIntance</a> ()</td></tr>
<tr class="separator:ad8c2e8259462504427739fbaf2e056bd"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pri-methods" name="pri-methods"></a>
Private 成员函数</h2></td></tr>
<tr class="memitem:ac45b6ef7069b222c094da3724d1aa8fb" id="r_ac45b6ef7069b222c094da3724d1aa8fb"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ac45b6ef7069b222c094da3724d1aa8fb">Logger</a> ()=default</td></tr>
<tr class="separator:ac45b6ef7069b222c094da3724d1aa8fb"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a10c246805aee7279977997e1ae6832ab" id="r_a10c246805aee7279977997e1ae6832ab"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a10c246805aee7279977997e1ae6832ab">setIsRunning</a> (bool isRunning)</td></tr>
<tr class="separator:a10c246805aee7279977997e1ae6832ab"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a69c0de1dd60ca195eb000a8fa94139a8" id="r_a69c0de1dd60ca195eb000a8fa94139a8"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a69c0de1dd60ca195eb000a8fa94139a8">threadExec</a> ()</td></tr>
<tr class="separator:a69c0de1dd60ca195eb000a8fa94139a8"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7d13896ef57933333ed113e6bef06b21" id="r_a7d13896ef57933333ed113e6bef06b21"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a7d13896ef57933333ed113e6bef06b21">setWriteBehavior</a> (<a class="el" href="class_log.html#ae9a5b0a1962f5076860bde2221f8e9e4">Log::Output</a> out)</td></tr>
<tr class="separator:a7d13896ef57933333ed113e6bef06b21"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6cf75422c01fb88b57f4b5f362f6d829" id="r_a6cf75422c01fb88b57f4b5f362f6d829"><td class="memItemLeft" align="right" valign="top"><a class="el" href="class_log.html">Log</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a6cf75422c01fb88b57f4b5f362f6d829">createLog</a> (std::string_view content, <a class="el" href="class_log.html#a3718f3e276c3d3e23b58a3b8236d196e">Log::LogLevel</a> level=<a class="el" href="class_log.html#a3718f3e276c3d3e23b58a3b8236d196eaa603905470e2a5b8c13e96b579ef0dba">Log::LogLevel::Debug</a>, <a class="el" href="class_log.html#ae9a5b0a1962f5076860bde2221f8e9e4">Log::Output</a> out=<a class="el" href="class_log.html#ae9a5b0a1962f5076860bde2221f8e9e4abccaa4aa80831b76c11240a16447975f">Log::Output::Console</a>, std::string_view path=&quot;./Log/&quot;, const std::source_location &amp;location=std::source_location::current())</td></tr>
<tr class="separator:a6cf75422c01fb88b57f4b5f362f6d829"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pri-attribs" name="pri-attribs"></a>
Private 属性</h2></td></tr>
<tr class="memitem:a710380268f6d4bb1bfa841e0d71b3868" id="r_a710380268f6d4bb1bfa841e0d71b3868"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a710380268f6d4bb1bfa841e0d71b3868">mIsRunning</a> {false}</td></tr>
<tr class="separator:a710380268f6d4bb1bfa841e0d71b3868"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac8ffdc12d6b2ded2029b8de314b2ba12" id="r_ac8ffdc12d6b2ded2029b8de314b2ba12"><td class="memItemLeft" align="right" valign="top">std::unique_ptr&lt; <a class="el" href="class_write.html">Write</a> &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ac8ffdc12d6b2ded2029b8de314b2ba12">writeBehavior</a></td></tr>
<tr class="separator:ac8ffdc12d6b2ded2029b8de314b2ba12"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a89fd90aeb0d8a6f67511e22b64d14eb6" id="r_a89fd90aeb0d8a6f67511e22b64d14eb6"><td class="memItemLeft" align="right" valign="top">std::mutex&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a89fd90aeb0d8a6f67511e22b64d14eb6">mMutex</a></td></tr>
<tr class="separator:a89fd90aeb0d8a6f67511e22b64d14eb6"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4b3566ea069cfd43703b194ce9846d5e" id="r_a4b3566ea069cfd43703b194ce9846d5e"><td class="memItemLeft" align="right" valign="top">std::deque&lt; <a class="el" href="class_log.html">Log</a> &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a4b3566ea069cfd43703b194ce9846d5e">mLogs</a></td></tr>
<tr class="separator:a4b3566ea069cfd43703b194ce9846d5e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9d7b008ee613498e7d2c6a320962555a" id="r_a9d7b008ee613498e7d2c6a320962555a"><td class="memItemLeft" align="right" valign="top">std::thread&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a9d7b008ee613498e7d2c6a320962555a">thread</a></td></tr>
<tr class="separator:a9d7b008ee613498e7d2c6a320962555a"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">详细描述</h2>
<div class="textblock"><dl class="section author"><dt>作者</dt><dd>liangxi </dd></dl>
<dl class="section since"><dt>自从</dt><dd>2024/3/20 </dd></dl>
</div><h2 class="groupheader">构造及析构函数说明</h2>
<a id="a68cafca721107a954d85043a553dd217" name="a68cafca721107a954d85043a553dd217"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a68cafca721107a954d85043a553dd217">&#9670;&#160;</a></span>~Logger()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual Logger::~Logger </td>
          <td>(</td>
          <td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span><span class="mlabel">default</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

</div>
</div>
<a id="ac45b6ef7069b222c094da3724d1aa8fb" name="ac45b6ef7069b222c094da3724d1aa8fb"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ac45b6ef7069b222c094da3724d1aa8fb">&#9670;&#160;</a></span>Logger()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">Logger::Logger </td>
          <td>(</td>
          <td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span><span class="mlabel">default</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

</div>
</div>
<h2 class="groupheader">成员函数说明</h2>
<a id="a3de1b6ed57224b98699fa1fb4d69537f" name="a3de1b6ed57224b98699fa1fb4d69537f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a3de1b6ed57224b98699fa1fb4d69537f">&#9670;&#160;</a></span>asyncLog()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void Logger::asyncLog </td>
          <td>(</td>
          <td class="paramtype">std::string_view</td>          <td class="paramname"><span class="paramname"><em>content</em></span>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="class_log.html#a3718f3e276c3d3e23b58a3b8236d196e">Log::LogLevel</a></td>          <td class="paramname"><span class="paramname"><em>level</em></span><span class="paramdefsep"> = </span><span class="paramdefval"><a class="el" href="class_log.html#a3718f3e276c3d3e23b58a3b8236d196eaa603905470e2a5b8c13e96b579ef0dba">Log::LogLevel::Debug</a></span>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="class_log.html#ae9a5b0a1962f5076860bde2221f8e9e4">Log::Output</a></td>          <td class="paramname"><span class="paramname"><em>out</em></span><span class="paramdefsep"> = </span><span class="paramdefval"><a class="el" href="class_log.html#ae9a5b0a1962f5076860bde2221f8e9e4abccaa4aa80831b76c11240a16447975f">Log::Output::Console</a></span>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">std::string_view</td>          <td class="paramname"><span class="paramname"><em>path</em></span><span class="paramdefsep"> = </span><span class="paramdefval">&quot;./AppLog/&quot;</span>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const std::source_location &amp;</td>          <td class="paramname"><span class="paramname"><em>location</em></span><span class="paramdefsep"> = </span><span class="paramdefval">std::source_location::current()</span>&#160;)</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>异步打印日志 </p><dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramname">content</td><td>需要打印的内容 </td></tr>
    <tr><td class="paramname">level</td><td>日志类型 </td></tr>
    <tr><td class="paramname">out</td><td>输出方式 </td></tr>
    <tr><td class="paramname">path</td><td>输出路径/在Console模式下可忽略 </td></tr>
    <tr><td class="paramname">location</td><td>用于记录文件名和行号</td></tr>
  </table>
  </dd>
</dl>
<dl class="section author"><dt>作者</dt><dd>liangxi </dd></dl>
<dl class="section since"><dt>自从</dt><dd>2024/3/20 </dd></dl>

</div>
</div>
<a id="a6cf75422c01fb88b57f4b5f362f6d829" name="a6cf75422c01fb88b57f4b5f362f6d829"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a6cf75422c01fb88b57f4b5f362f6d829">&#9670;&#160;</a></span>createLog()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="class_log.html">Log</a> Logger::createLog </td>
          <td>(</td>
          <td class="paramtype">std::string_view</td>          <td class="paramname"><span class="paramname"><em>content</em></span>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="class_log.html#a3718f3e276c3d3e23b58a3b8236d196e">Log::LogLevel</a></td>          <td class="paramname"><span class="paramname"><em>level</em></span><span class="paramdefsep"> = </span><span class="paramdefval"><a class="el" href="class_log.html#a3718f3e276c3d3e23b58a3b8236d196eaa603905470e2a5b8c13e96b579ef0dba">Log::LogLevel::Debug</a></span>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="class_log.html#ae9a5b0a1962f5076860bde2221f8e9e4">Log::Output</a></td>          <td class="paramname"><span class="paramname"><em>out</em></span><span class="paramdefsep"> = </span><span class="paramdefval"><a class="el" href="class_log.html#ae9a5b0a1962f5076860bde2221f8e9e4abccaa4aa80831b76c11240a16447975f">Log::Output::Console</a></span>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">std::string_view</td>          <td class="paramname"><span class="paramname"><em>path</em></span><span class="paramdefsep"> = </span><span class="paramdefval">&quot;./Log/&quot;</span>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const std::source_location &amp;</td>          <td class="paramname"><span class="paramname"><em>location</em></span><span class="paramdefsep"> = </span><span class="paramdefval">std::source_location::current()</span>&#160;)</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

</div>
</div>
<a id="ad8c2e8259462504427739fbaf2e056bd" name="ad8c2e8259462504427739fbaf2e056bd"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ad8c2e8259462504427739fbaf2e056bd">&#9670;&#160;</a></span>getIntance()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static <a class="el" href="class_logger.html">Logger</a> &amp; Logger::getIntance </td>
          <td>(</td>
          <td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

</div>
</div>
<a id="a10c246805aee7279977997e1ae6832ab" name="a10c246805aee7279977997e1ae6832ab"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a10c246805aee7279977997e1ae6832ab">&#9670;&#160;</a></span>setIsRunning()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void Logger::setIsRunning </td>
          <td>(</td>
          <td class="paramtype">bool</td>          <td class="paramname"><span class="paramname"><em>isRunning</em></span></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

</div>
</div>
<a id="a7d13896ef57933333ed113e6bef06b21" name="a7d13896ef57933333ed113e6bef06b21"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a7d13896ef57933333ed113e6bef06b21">&#9670;&#160;</a></span>setWriteBehavior()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void Logger::setWriteBehavior </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="class_log.html#ae9a5b0a1962f5076860bde2221f8e9e4">Log::Output</a></td>          <td class="paramname"><span class="paramname"><em>out</em></span></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

</div>
</div>
<a id="adcdbfe0302dd53c9db3d355ddee8a3b6" name="adcdbfe0302dd53c9db3d355ddee8a3b6"></a>
<h2 class="memtitle"><span class="permalink"><a href="#adcdbfe0302dd53c9db3d355ddee8a3b6">&#9670;&#160;</a></span>startLogThread()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void Logger::startLogThread </td>
          <td>(</td>
          <td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>启动日志线程 在异步输出日志之前调用 </p>

</div>
</div>
<a id="aa223fb9d3d6becff1ee3ae8c40ec11f3" name="aa223fb9d3d6becff1ee3ae8c40ec11f3"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa223fb9d3d6becff1ee3ae8c40ec11f3">&#9670;&#160;</a></span>stopLogThread()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void Logger::stopLogThread </td>
          <td>(</td>
          <td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>停止日志线程 </p>

</div>
</div>
<a id="a67fac285fd603d742a2e0eea7783e9b6" name="a67fac285fd603d742a2e0eea7783e9b6"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a67fac285fd603d742a2e0eea7783e9b6">&#9670;&#160;</a></span>syncLog()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void Logger::syncLog </td>
          <td>(</td>
          <td class="paramtype">std::string_view</td>          <td class="paramname"><span class="paramname"><em>content</em></span>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="class_log.html#a3718f3e276c3d3e23b58a3b8236d196e">Log::LogLevel</a></td>          <td class="paramname"><span class="paramname"><em>level</em></span><span class="paramdefsep"> = </span><span class="paramdefval"><a class="el" href="class_log.html#a3718f3e276c3d3e23b58a3b8236d196eaa603905470e2a5b8c13e96b579ef0dba">Log::LogLevel::Debug</a></span>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="class_log.html#ae9a5b0a1962f5076860bde2221f8e9e4">Log::Output</a></td>          <td class="paramname"><span class="paramname"><em>out</em></span><span class="paramdefsep"> = </span><span class="paramdefval"><a class="el" href="class_log.html#ae9a5b0a1962f5076860bde2221f8e9e4abccaa4aa80831b76c11240a16447975f">Log::Output::Console</a></span>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">std::string_view</td>          <td class="paramname"><span class="paramname"><em>path</em></span><span class="paramdefsep"> = </span><span class="paramdefval">&quot;./AppLog/&quot;</span>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const std::source_location &amp;</td>          <td class="paramname"><span class="paramname"><em>location</em></span><span class="paramdefsep"> = </span><span class="paramdefval">std::source_location::current()</span>&#160;)</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>同步打印日志 </p><dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramname">content</td><td></td></tr>
    <tr><td class="paramname">level</td><td></td></tr>
    <tr><td class="paramname">out</td><td></td></tr>
    <tr><td class="paramname">path</td><td></td></tr>
    <tr><td class="paramname">location</td><td></td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="a69c0de1dd60ca195eb000a8fa94139a8" name="a69c0de1dd60ca195eb000a8fa94139a8"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a69c0de1dd60ca195eb000a8fa94139a8">&#9670;&#160;</a></span>threadExec()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void Logger::threadExec </td>
          <td>(</td>
          <td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

</div>
</div>
<h2 class="groupheader">类成员变量说明</h2>
<a id="a710380268f6d4bb1bfa841e0d71b3868" name="a710380268f6d4bb1bfa841e0d71b3868"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a710380268f6d4bb1bfa841e0d71b3868">&#9670;&#160;</a></span>mIsRunning</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">bool Logger::mIsRunning {false}</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

</div>
</div>
<a id="a4b3566ea069cfd43703b194ce9846d5e" name="a4b3566ea069cfd43703b194ce9846d5e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a4b3566ea069cfd43703b194ce9846d5e">&#9670;&#160;</a></span>mLogs</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">std::deque&lt;<a class="el" href="class_log.html">Log</a>&gt; Logger::mLogs</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

</div>
</div>
<a id="a89fd90aeb0d8a6f67511e22b64d14eb6" name="a89fd90aeb0d8a6f67511e22b64d14eb6"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a89fd90aeb0d8a6f67511e22b64d14eb6">&#9670;&#160;</a></span>mMutex</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">std::mutex Logger::mMutex</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

</div>
</div>
<a id="a9d7b008ee613498e7d2c6a320962555a" name="a9d7b008ee613498e7d2c6a320962555a"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a9d7b008ee613498e7d2c6a320962555a">&#9670;&#160;</a></span>thread</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">std::thread Logger::thread</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

</div>
</div>
<a id="ac8ffdc12d6b2ded2029b8de314b2ba12" name="ac8ffdc12d6b2ded2029b8de314b2ba12"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ac8ffdc12d6b2ded2029b8de314b2ba12">&#9670;&#160;</a></span>writeBehavior</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">std::unique_ptr&lt;<a class="el" href="class_write.html">Write</a>&gt; Logger::writeBehavior</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

</div>
</div>
<hr/>该类的文档由以下文件生成:<ul>
<li>Log/Header/<a class="el" href="_logger_8h_source.html">Logger.h</a></li>
<li>Log/Source/<a class="el" href="_logger_8cpp.html">Logger.cpp</a></li>
</ul>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
制作者&#160;<a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.12.0
</small></address>
</div><!-- doc-content -->
</body>
</html>
